<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<table border="1">
    <caption>用户列表</caption>
    <tr>
        <th>用户名</th>
        <th>密码</th>
        <th>昵称</th>
    </tr>
</table>
<script>
    let arr = [{name:"张三",password:123123,nickname:"三" },
        {name:"李四",password:123123123123123,nickname:"四" },
        {name:"老八",password:456343,nickname:"八" },
        {name:"徐静雨",password:123123,nickname:"鲸鱼" }
    ]
    let table = document.querySelector("table");
    for (let userinfo of arr) {
        let tr = document.createElement("tr");
        let name = document.createElement("td");
        let password = document.createElement("td");
        let nickname = document.createElement("td");
        name.innerText = userinfo.name;
        password.innerText = userinfo.password;
        nickname.innerText = userinfo.nickname;
        tr.append(name,password,nickname);
        table.append(tr);
    }
</script>
</body>
</html>